1. Technical Field
The present disclosure relates to a filtering device which appropriately derives a difference value (parallax) of an object in multiple comparison targets.
2. Related Art
There are conventionally known a technique, such as collision avoidance control, which detects specific objects including another vehicle located ahead of a vehicle, and avoids a collision with a leading vehicle, and a technique, such as a cruise control, which controls so as to maintain an inter-vehicle distance with a leading vehicle at a safe distance (for instance, see Japanese Patent (JP-B) No. 3,349,060).
Such a collision-avoidance control and cruise control derive parallaxes by using so-called pattern matching in order to acquire a relative distance from the vehicle, of an object located ahead of the vehicle. The pattern matching acquires image data from, for example, each of two imaging devices of which viewpoints differ from each other. The pattern matching then extracts any one of blocks (hereinafter, referred to as “the reference block”) from an image (hereinafter, referred to as “the reference image”) based on the image data generated by one of the imaging devices, and searches a highly-correlated block (hereinafter, referred to as “the comparison block”) from an image (hereinafter, referred to as “the comparison image”) based on the image data generated by the other imaging device. Then, the pattern matching refers to imaging parameters, such as installed positions and focal lengths of the imaging devices, uses so-called a stereo method or a triangulation method to calculate relative distance of the object with respect to the imaging devices based on the derived parallax, and converts the calculated relative distance into three-dimensional (3D) positional information which contains a horizontal distance and a height of the object in addition to the calculated relative distances. Further, various recognition processing are performed using the 3D positional information. Note that the term “horizontal” as used herein refers to screen transverse or lateral directions, and the term “vertical (described later)” as used herein refers to screen vertical directions which are perpendicular to the horizontal directions.
The pattern matching calculates a correlation of a block in the comparison image with each block in the reference image, while horizontally shifting the block in the comparison image, and uses a difference (difference values) in coordinates between the comparison image of the most-correlated block and the corresponding block in the reference images as the parallax. However, various objects exist ahead of the vehicle and the images may contain multiple similar objects and/or one object may contain similar subject parts. Typical examples of the similar objects and similar subject parts include a series of pylons, lighting posts or telegraph poles on road, and predetermined parts of a vehicle. If such similar objects and/or similar subject parts are located horizontally, one object and/or subject part may be matched with another similar object and/or subject part, leading to an erroneous derivation of the parallax.
For this reason, for example, JP-B No. 3,287,465 discloses a technique of the pattern matching that, determine when one comparison block of the comparison image has highest correlation with multiple reference blocks of the reference image (this event is simply referred to as “pairing”), determines only a parallax regarding one of the reference blocks having the minimum parallax to be valid.
However, since the technique disclosed in JP-B No. 3,287,465 excludes the parallax (difference value) regarding the reference block which was not determined to be valid, the comparison block corresponding to the reference block concerned is processed not to be existed although the comparison block actually exists. Further, if multiple comparison blocks corresponding to multiple reference blocks have matched with each other accidentally, that is, if one reference block is matched with a comparison block corresponding to another reference block and a comparison block corresponding to the one reference block associates with another reference block (this event is simply referred to as “the crossing pairing”), the technique disclosed in JP-B No. 3,287,465 cannot correct this erroneous matching.